package semant;

import syntaxtree.Program;
import errors.ErrorEchoer;
import semant.first_pass.FirstPass;
import semant.second_pass.SecondPass;

public class TypeChecker
{
    private TypeChecker()
    {
        super();
    }

    public static Env TypeCheck(ErrorEchoer err, Program p)
    {		
        Env e = FirstPass.firstPass(err, p);

        SecondPass.secondPass(e,p);

        return e;
    }
}
